﻿using System;
using System.Collections.Generic;
using UnityEngine;

// Token: 0x020002BE RID: 702
internal class ExpressionNameSet
{
	// Token: 0x0600120B RID: 4619 RVA: 0x00076714 File Offset: 0x00074914
	public ExpressionNameSet(TextAsset eyeList, TextAsset mouthList)
	{
		ExpressionNameSet.Setup_Dictionary(this.eyeDic, eyeList);
		ExpressionNameSet.Setup_Dictionary(this.mouthDic, mouthList);
	}

	// Token: 0x0600120C RID: 4620 RVA: 0x0007674C File Offset: 0x0007494C
	public string EyeName(string name)
	{
		if (this.eyeDic.ContainsKey(name))
		{
			return this.eyeDic[name];
		}
		GlobalData.Debug_LogError("眼睛的表情：" + name + " 找不到");
		return "Eye_Def";
	}

	// Token: 0x0600120D RID: 4621 RVA: 0x00076788 File Offset: 0x00074988
	public string MouthName(string name)
	{
		if (this.mouthDic.ContainsKey(name))
		{
			return this.mouthDic[name];
		}
		GlobalData.Debug_LogError("嘴巴的表情：" + name + " 找不到");
		return "Mouth_Def";
	}

	// Token: 0x0600120E RID: 4622 RVA: 0x000767C4 File Offset: 0x000749C4
	private static void Setup_Dictionary(Dictionary<string, string> dic, TextAsset text)
	{
		CustomDataListLoader customDataListLoader = new CustomDataListLoader();
		customDataListLoader.Load(text);
		int attributeNo = customDataListLoader.GetAttributeNo("anime");
		int attributeNo2 = customDataListLoader.GetAttributeNo("name");
		for (int i = 0; i < customDataListLoader.GetDataNum(); i++)
		{
			string data = customDataListLoader.GetData(attributeNo, i);
			string data2 = customDataListLoader.GetData(attributeNo2, i);
			dic.Add(data2, data);
		}
	}

	// Token: 0x040013DD RID: 5085
	private Dictionary<string, string> eyeDic = new Dictionary<string, string>();

	// Token: 0x040013DE RID: 5086
	private Dictionary<string, string> mouthDic = new Dictionary<string, string>();
}
